import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'


import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';

// 用这个来网路请求
import api from "@/config/api";

import utils from "@/config/utils";
import "@/assets/css/pc.css";


import Print from 'vue-print-nb'

Vue.use(Print);

// 绑定api
Vue.prototype.$api = api;

// 绑定工具
Vue.prototype.$utils = utils;


Vue.use(ElementUI);


Vue.config.productionTip = false


// 判断用户信息
let userId = utils.getUserId();
if(userId){
  // 说明记录的有登陆
  store.dispatch("getUserById",userId);
}


new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
